package com.wms.service.impl;

import com.wms.entity.OrderPlatform;
import com.wms.entity.OrderPlatformDTO;
import com.wms.mapper.OrderPlatformMapper;
import com.wms.service.OrderPlatformService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.Collections;
import java.util.List;

/**
 * ---Do First---
 *
 * @author:wellseasun
 * @date:2025/4/28 下午 9:29
 * @desc:
 */
@Service
public class OrderPlatformServiceImpl implements OrderPlatformService {

    @Autowired
    private OrderPlatformMapper orderPlatformMapper;

    @Override
    public List<OrderPlatform> findAllByPage(OrderPlatformDTO orderPlatformDTO) {
        return orderPlatformMapper.findAllByPage(orderPlatformDTO);
    }

    @Override
    public Boolean add(OrderPlatform orderPlatform) {
        return orderPlatformMapper.add(orderPlatform);
    }

    @Override
    public Boolean deleteOrderPurchase(List<Integer> ids) {
        return orderPlatformMapper.deleteOrderPurchase(ids);
    }

    @Override
    public Boolean updateOrderPurchase(OrderPlatform orderPlatform) {
        return orderPlatformMapper.updateOrderPurchase(orderPlatform);
    }

    @Override
    public void insertBatch(List<OrderPlatform> cachedDataList) {
        orderPlatformMapper.insertBatch(cachedDataList);
    }
}
